{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<IntegerArray>\n",
      "[1, 2, 3]\n",
      "Length: 3, dtype: Int64\n"
     ]
    }
   ],
   "source": [
    "import pandas as pd\n",
    "hh=pd.array([1,2,3])\n",
    "print(hh)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "hello world\n",
      "hello world hello world\n",
      "1212\n",
      "0b1010\n",
      "2\n",
      "rs=3,num2=2\n",
      "True\n",
      "True\n",
      "False\n"
     ]
    }
   ],
   "source": [
    "# 注释\n",
    "\"\"\"\n",
    "多行注释\n",
    "\"\"\"\n",
    "print(\"hello world\")\n",
    "print(\"hello world\", end=\" \")  # 空格覆盖默认换行\n",
    "print(\"hello world\")\n",
    "print(\"1212\", end=\"\\n\")\n",
    "\n",
    "#  标识符不能由数字和下划线开头\n",
    "num = 10\n",
    "#二进制转化\n",
    "print(bin(num))\n",
    "\n",
    "#  python中\"//\"表示整除\n",
    "print(10//5)\n",
    "\n",
    "# 海象运算符  :=\n",
    "rs=1+(num2:=2)\n",
    "print(f\"rs={rs},num2={num2}\")\n",
    "# 它的作用是将表达式的值赋值给变量，然后返回表达式的值。\n",
    "\n",
    "#  与或非 and or not 优先级 not > and > no\n",
    "print(6 > 5 and 1 < 2)\n",
    "print(6 > 5 or 1 > 2)\n",
    "print(not 6 > 5)"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "pytorch1",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.11.8"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
